<?php
class Billing extends MY_Controller 
{
	var $curl = 'billing';
	var $name = '';
	var $search = '';
	var $per_page = 0;
	var $language;
	var $submenu = "_menu";
	var $id_user = '';
	
	function __construct()
	{
		parent::__construct();
		
		$this->load->model(array('/public/billing_model', '/public/account_type_model'));

		$this->validation->set_fields($this->billing_model->fields);
		
		$this->data['Title'] = T_('Billing History');		

		$this->language = parent::getLang();

		$this->name = T_('Billing History');
	}

	function search_autocomplete()
	{
		//echo $this->billing_model->search_autocomplete();
	}
	
	function index()
	{		
		$this->renderLayout();
	}

	function contributors()
	{
		$this->billing_model->search();
		
		$this->data['Title'] = T_('Paying Authors');
		
		$this->renderLayout();
	}
	
	function companies()
	{
		$this->billing_model->search();
		
		$this->data['Title'] = T_('Billing Companies');
		
		$this->renderLayout();
	}
	
	function deleteItems()
	{		
		$data = $this->billing_model->delete($_REQUEST['items']);

		echo $data;
	}

	function delete($id)
  	{
  		/*
    	$data = $this->billing_model->delete($id);

    	redirect($this->curl . '/index');*/
  	}	
}
?>